	<div id ="sub-menu">
	<%= link_to 'Afficher', {:controller => "machines", :action => "show"}, :class => "bouton" %> 
	<%= link_to 'Retour', {:controller => "machines", :action => "index"}, :class => "bouton" %>
 	</div>	

    
 <div id="formulaire">
	<h3>Editer la machine id: <%= @machine.id %> </h3>
	
	<% form_for(@machine) do |f| %>
		<%= f.error_messages %>
		 <table class="table-form">	
		 	<tr>
			<td>Nom machine :</td>
			<td><%= f.text_field :machine_name %></td>
			</tr>
			
			<tr>
			<td>Numéro Série :</td>
			<td><%= f.text_field :serial_number %></td>
			</tr>
			
			<tr>
			<td>Adresse IP :</td>
			<td><%= f.text_field :ip_adr %></td>
			</tr>
			
			<tr>
			<td>Salle :</td>
			<td><%= f.select("room_id", Room.all.collect {|r| [r.room_name, r.id]}, {:prompt => 'Sélectionner une salle'}) %></td>
			</tr>
			
		</table>		
			<%= f.submit 'Mettre à jour', :class => "bouton1" %>
	<% end %>

</div>


